#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
using namespace std;
class Solution {
public:
    string PrintMinNumber(vector<int> numbers) {

    	if(numbers.empty())
    		return "";
    	sort(numbers.begin(),numbers.end());
        string output(to_string(numbers[0]));
        for(int i = 1 ; i < numbers.size() ; ++i)
        {
        	output = compareNumber(output+to_string(numbers[i]), to_string(numbers[i]) +output);
        }
        return output;
    }

    string compareNumber(string a,string b)
    {
    	if(a > b)
    		return b;
    	return a;
    }
};

int main()
{
	Solution s;
	string str = s.PrintMinNumber(vector<int>{32,3,213});
	cout<<str<<endl;
	return 0;
}